/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.posplus.losspreventiondataimporter.util;

import java.util.Calendar;

/**
 *
 * @author scottw
 */
public class Util {
    public static String toString(Calendar cal){
        StringBuilder builder = new StringBuilder();
        
        builder.append(cal.get(Calendar.YEAR))
                .append("-")
                .append(cal.get(Calendar.MONTH))
                .append("-")
                .append(cal.get(Calendar.DAY_OF_MONTH))
                .append(" ")
                .append(cal.get(Calendar.HOUR_OF_DAY))
                .append(":")
                .append(cal.get(Calendar.MINUTE))
                .append(":")
                .append(cal.get(Calendar.SECOND));
        
        return builder.toString();
    }
}
